//====调用函数文件
@import "../../../easy-style/screen";
@import "../block/function";
@import "../block/icon";

//====浏览器支持度
$ex-support-for-ie6: false;
$ex-support-for-ie7: false;
$ex-support-for-webkit533: false;
$ex-support-for-owg: false;

//====全局变量
$sprites-bg: false; //是否使用sprites背景图片
$sliding-bg: false; //是否使用sliding图片
$sliding-bg-img: null; //全局滑动门图片
$main-bg-img: null; //全局主背景图
$main-repeat-bg: false; //全局平铺背景
$main-color: #007de6; //页面主色(原)
$main-dark-color: #1f273b;   //页面主色(深)
$main-light-color: #f4f4f4;  //页面主色(浅)
$main-text-color: #646464; //页面普通文本色
$main-bg-color: $main-light-color; //全局主背景色
$main-border-color: $ge; //全局主背景色
$main-divider-color: $gd; //全局主背景色
$primary-text-color: $g3; //页面重要文本色
$minor-text-color: #949494; //页面次要文本色

$color-success: #51dd3a;
$color-warn: #ffc543;
$color-error: #fa4251;

$a-color: #55a8fd;           //链接主色
$a-hover-color: $main-color; //鼠标经过时链接主色

//-----------------------------------------------------------------
//-----                   aside(侧边栏设置)                    -----
//-----------------------------------------------------------------

//======    1.侧边栏(aside)     ======
$aside-width: 100px; //侧边菜单栏度
$aside-bg: $main-dark-color; //侧边菜单栏背景

//======    2.导航栏   ======
$nav-img-theme: false; //是否启用默认图片背景
$nav-bg-img: false; //导航背景图
$nav-bg: $nav-bg-img; //导航背景
$nav-bg-on: false; //导航背景
$nav-icon-color: #537eb6; //导航图标色

$nav-margin: 0; //一级导航间距
$nav-height: false 20px; //一级导航项高度
$nav-text-size: 14px; //一级导航文字大小
$nav-text-color: $ge; //一级导航文字颜色
$nav-text-hover-color: $gf; //一级导航文字鼠标经过颜色
$nav-current-bg: $gf; //一级导航活动链接背景,false时没有背景
$nav-current-text-color: $main-dark-color; //一级导航活动链接颜色

$nav-slide-padding: 5px 10px 0; //一级导航滑动门间距
$nav-bg: false; //一级导航左滑动门背景
$nav-rbg: false; //一级导航右滑动门背景
$nav-hover-bg: #f8f8f8; //一级导航鼠标经过时左滑动门背景
$nav-hover-rbg: false; //一级导航鼠标经过时右滑动门背景

//======    3.logo   ======
$logo-height: 80px;

@mixin logo-box {
  display: table-cell;
  height: $logo-height;
  padding: 15px;
  margin-bottom: 0;
  line-height: 20px;
  vertical-align: middle;
  background-color: #21325c;
  // font-size: 18px;
  // font-weight: 500;
  // color: #563d7c;

  a {
    // text-decoration: none;
    // vertical-align: middle;

    img {
      max-width: 100%;
      max-height: 100%;
      vertical-align: middle;
    }
  }
}

//-----------------------------------------------------------------
//-----                   header(头部设置)                    -----
//-----------------------------------------------------------------

//======    1.头部   ======
$header-img-theme: false; //是否启用默认图片背景
$header-bg-img: $main-repeat-bg; //头部背景图

$header-bg: $gf; //头部背景
$header-height: 100px; //头部高度

//======    2.顶部工具栏   ======
$topbar-padding: false; //顶部工具栏边距
$topbar-border: 1px solid $gc; //gray_bg($main-color,#E9CFBC) 顶部工具栏边框
$topbar-bg: #f8f8f8; //顶部工具栏背景
$topbar-height: 26px; //工具栏高度
$topbar-text-color: $main-text-color; //工具栏普通文本颜色
$topbar-a-color: $main-text-color; //工具栏链接颜色
$topbar-a-hover-color: false; //工具栏鼠标经过字体颜色
$topbar-a-hover-bg: false; //工具栏鼠标经过背景,false时表示没有背景

@mixin topbar-css3 {
  //顶部工具栏css3效果,在此mixin中写css3属性即可
  @include border-radius(3px 00003px);
  @include box-shadow(0 0 1px $gd, inset 0 5px 8px rgba(150, 150, 150, 0.1));

  // &:hover {
  //   @include box-shadow(0 0 4px $gb);
  // }
}

@mixin topbar-text-css3 {
  //顶部工具栏按钮碰触css3效果,在此mixin中写css3属性即可
  @include border-radius(3px);
  @include box-shadow(0 1px 2px rgba(0, 0, 0, 0.4));
}

//-----------------------------------------------------------------
//-----                  side(侧边栏)                         -----
//-----------------------------------------------------------------

//======    1.左侧栏(side)     ======
$side-width: 120px; //左边栏宽度

$side-img-theme: false; //是否启用默认图片背景
$side-bg-img: $main-bg-img; //左侧边栏背景图

$side-open-title: false; //侧边栏标题图标(展开时),false时没有背景
$side-close-title: false; //侧边栏标题图标(收起时),false时没有背景
$side-title-color: #95a0a8; //侧边栏标题颜色
$side-title-size: 14px; //侧边栏标题颜色
$side-box-split-line: gray_bg($main-color, #e2cfc1); //分割线颜色

$side-bg: $main-bg-color; //侧边栏二级导航背景
$side-border: $ge; //二级导航弹出层边框
$side-text-color: $main-text-color; //二级导航文字颜色
$side-text-hover-color: $primary-text-color; //二级导航鼠标经过文字颜色
$side-text-hover-bg: $gf; //二级导航文字鼠标经过背景,false时没有背景
$side-hover-bg: $gf; //二级导航鼠标经过底色
$side-current-text-color: $primary-text-color; //活动链接颜色
$side-current-bg: $gf; //活动链接背景,false时没有背景

//======    2.右侧栏(side-r)     ======
$side-r-width: 250px; //右边栏宽度
$side-r-bg: #ffffff; //侧边栏背景
$side-r-border: false; //右侧边栏边框

$side-r-resize-ing-bg: gray_bg($main-color, #96654f); //右边栏拖动条背景

//-----------------------------------------------------------------
//-----                  content(主内容区)                    -----
//-----------------------------------------------------------------

//======    1.左侧开关(toggler-left)   ======
$toggler-img-theme: false; //是否启用默认背景图片
$toggler-bg-img: false; //背景图片

$toggler-bg: $toggler-bg-img; //背景
$toggler-hover-bg: $toggler-bg-img; //鼠标经过背景

//======    2.控制面板(admin-panel)   ======
$admin-panel-text-hover-color: $gf; //链接颜色
$admin-panel-text-hover-bg: $main-color; //文字鼠标经过背景,false时没有背景

//======    3.桌面(dashboard)   ======
$dashbd-img-theme: true; //是否启用默认背景图片
$dashbd-bg-img: $main-repeat-bg; //背景图片

$dashbd-bg: $gf; //桌面模块背景

$dashbd-head-bg: $dashbd-bg-img; //模块头部背景
$dashbd-head-height: 32px; //模块头部高度
$dashbd-title-bg: false; //头部标题背景
$dashbd-title-color: $g3; //头部标题文字颜色

$dashbd-list-border-color: $main-border-color; //主内容边框
$dashbd-list-title-color: $g5; //主内容标题颜色
$dashbd-list-title-size: 16px; //主内容标题大小
$dashbd-figure-text-color: #ff6900; //数字提示颜色

$dashbd-figure-zero-color: #7b7b7b; //无提示文字颜色
$dashbd-figure-zero-text-color: #b2b2b2; //数字为0时提示颜色

//======    4.页脚(foot)   ======
$foot-height: 60px;
$foot-bg-color: $main-bg-color;

//-----------------------------------------------------------------
//-----                  component(功能组件)                  -----
//-----------------------------------------------------------------

//======    1.翻页(pager)   ======
$pager-text-size: 0.9em; //文字大小

$pager-border: 1px solid $main-light-color; //非活动页码边框
$pager-text: $main-text-color; //非活动页码文字颜色
$pager-bg: $main-bg-color; //非活动页码文字颜色

$pager-active-border: 1px solid $main-dark-color; //活动页码边框色
$pager-active-bg: $main-color; //活动页码背景色
$pager-active-text: $gf; //活动页码文字颜色

//======    2.对话框(dialog)   ======
$dialog-img-theme: false; //是否启用默认背景图片
$dialog-bg-img: $main-bg-img !default; //背景图片
$dialog-repeat-bg: $main-repeat-bg !default; //背景平铺图片

$dialog-bg: $gf; //dialog背景
$dialog-border: 1px solid gray_bg($main-color, #9c8571); //dialog边框

$dialog-head-bg: $main-bg-color; //头部背景
$dialog-title-height: 40px; //头部高度
$dialog-title-color: $main-color; //dialog标题颜色
$dialog-title-size: 14px; //dialog标题大小

$dialog-content-head-bg: null; //主内容头部背景
$dialog-content-foot-bg: null; //主内容脚部背景

//======    3.tab   ======

//-----------------------------------------------------------------
//-----                  button(系统按钮)                     -----
//-----------------------------------------------------------------

//=====默认按钮=======
$button-img-theme: false; //是否启用默认背景图片
$button-bg-img: btn; //按钮背景图

$button-text-color: $main-color !default; //按钮文本色
$button-text-color-on: $main-color !default; //活动按钮文本色
$button-text-color-off: $g9 !default; //不可用按钮文本色
$button-bg: $gf !default; //按钮背景
$button-bg-on: $main-light-color !default; //活动按钮背景
$button-bg-act: $main-light-color !default; //高亮按钮背景
$button-bg-off: $ge !default; //不可用按钮背景
$button-border: 1px solid $main-divider-color !default; //按钮边框
$button-border-on: $main-divider-color !default; //按钮边框
$button-border-off: $ge !default; //按钮边框
$button-color-primary: $gf;
$button-color-primary-on: $gf;
$button-bg-primary: $main-color; //主按钮背景
$button-bg-primary-on: #4ea2eb;
$button-bg-primary-off: btn_primary_off;
$button-bg-primary-act: btn_primary_act;
$button-border-primary: $button-bg-primary;
$button-border-primary-on: darken($button-bg-primary-on, 3%);
$button-color-secondary: $g3;
$button-color-secondary-on: $g2;
$button-bg-secondary: btn_secondary;
$button-bg-secondary-on: btn_secondary_on;
$button-bg-secondary-off: btn_primary_off;
$button-bg-secondary-act: btn_secondary_act;
$button-bg-thirdly: btn_thirdly;
$button-bg-thirdly-on: btn_thirdly_on;
$button-bg-fourthly: btn_fourthly;
$button-bg-fourthly-on: btn_fourthly_on;
$button-bg-fifthly: btn_five;
$button-bg-fifthly-on: btn_five_on;
$button-bg-dark: btn_dark;
$button-bg-green: btn_green;
$button-bg-green-on: btn_green_on;

//=====有图标按钮======
$icon-img-theme: false; //是否启用默认背景图片
$icon-bg-img: 'sysicon'; //按钮图标

$icon-bg-color: gray_bg($main-color, #e8e5e2); //按钮背景色

$icon-add: url(../../images/bundle/add.gif) no-repeat;
$icon-add-color: gray_bg($main-color, #ebe8e2);
$icon-delete: url(../../images/bundle/delete.gif) no-repeat;
$icon-delete-color: gray_bg($main-color, #ebe8e2);
$icon-edit: url(../../images/bundle/edit.gif) no-repeat;
$icon-print: url(../../images/bundle/print.gif) no-repeat;
$icon-print-color: gray_bg($main-color, #ebe8e2);
$icon-cal-color: $gf;
$icon-cal: $icon-cal-color;
$icon-enable: enabled;
$icon-enable-color: gray_bg($main-color, #ebe8e2);
$icon-sms: sms;
$icon-sms-color: gray_bg($main-color, #ebe8e2);
$icon-email: mail;
$icon-email-color: gray_bg($main-color, #ebe8e2);

//=====无图标按钮======
$noicon-bg-color: gray_bg($main-color, #ebe8e2); //按钮背景色

//=====树型菜单======
$imgtree-img-theme: true; //是否启用默认背景图片
$imgtree-bg-img: "treeico.gif"; //图标

$imgtree-bg: $imgtree-bg-img;

//-----------------------------------------------------------------
//-----                  gridlist(表格)                       -----
//-----------------------------------------------------------------

//======gridlist=========
$gridlist-action-img-theme: false; //是否启用默认背景图片
$gridlist-action-repeat-bg: $main-repeat-bg;

$gridlist-action-bg: #ffffff;
$gridlist-action-text-color: $main-text-color;

//======finder action======
$finder-action-img-theme: false; //是否启用默认背景图片
$finder-action-bg-img: action_item;
$finder-action-bg-img-on: action_item_on;
$finder-action-repeat-bg: $main-repeat-bg;

$finder-action-bg: false;

@mixin finder-action-box {
  @include rect($padding: 10px, $position: relative z 99, $margin: -1px top);
}

$finder-action-item-color: $main-text-color;
$finder-action-item-lbg: #efefef;
$finder-action-item-rbg: #efefef;
$finder-action-item-hover-lbg: $finder-action-bg-img-on;
$finder-action-item-hover-rbg: $finder-action-bg-img-on;

//======finder action group======
$finder-action-group-img-theme: true; //是否启用默认背景图片
$arrow-down: "arrow-down.gif";
$arrow-up: "arrow-up.gif";
$arrow-left: "arrow-left.gif";
$arrow-right: "arrow-right.gif";

//======finder packet======
$finder-packet-img-theme: false; //是否启用默认背景图片
$finder-packet-bg-img: finder_packet;
$finder-packet-bg-img-on: finder_packet_on;

$finder-packet-lbg: transparent; //左滑动门图片
$finder-packet-rbg: transparent; //右滑动门图片
$finder-packet-height: 22px; //tab高度
$finder-packet-text-color: $g9; //文字颜色
$finder-packet-current-lbg: false; //左活动滑动门图片
$finder-packet-current-rbg: false; //右活动滑动门图片
$finder-packet-current-text-color: $main-text-color; //文字颜色
$finder-packet-current-height: 38px; //tab current 时高度

//======finder-cell-opt=====
$finder-detail-content-bg: $gf;
$finder-detail-content-bg-color: $gf;

$finder-img-tip-bg: photography;

$gift-name-bg: gift;

//======lnk-operation lnk-refresh
$lnk-img-theme: false; //是否启用默认背景图片
$lnk-bg-img: false; //背景图

$lnk-refresh-bg: $lnk-bg-img; //refresh背景图
$lnk-refresh-hover-bg: $lnk-bg-img; //refresh hover背景图
$lnk-operation-bg: $lnk-bg-img; //operation背景图
$lnk-operation-hover-bg: $lnk-bg-img; //operation hover背景图
$lnk-search-bg: $lnk-bg-img; //search背景图
$lnk-search-hover-bg: $lnk-bg-img; //search hover背景图

//======finder tab wrap
$finder-tab-wrap-bg: finder_tab_wrap;
$finder-tab-wrap-bg-on: finder_tab_wrap_on;

//-----------------------------------------------------------------
//-----                  singlepage(弹出页面)                 -----
//-----------------------------------------------------------------

//=====左侧边栏=====
$sing-side-img-theme: true; //是否启用默认图片背景

$sing-side-current-bg: $side-bg-img; //活动链接背景,false时没有背景

//-----------------------------------------------------------------
//-----                 滚动条配置                            -----
//-----------------------------------------------------------------
$scrollbar-corner-bg: $f0;
$scrollbar-resize-bg: $f3;
$scrollbar-radius: 7px;
$scrollbar-button-bg: url(images/scroll-arrow.png) no-repeat;
$scrollbar-thumb-bg-from: #dee2ec;
$scrollbar-thumb-bg-to: #b6c0d5;
$scrollbar-thumb-shadow-bg: $gc;
$scrollbar-thumb-inactive-bg: $f0;
$scrollbar-track-piece-bg: #ebeff4;

//webkit核心浏览器下滚动条样式
@mixin webkit-scrollbar($size: 5px, $corner-bg: $gf, $piece-bg: null, $piece-radius: null, $resize-bg: $f6, $button-bg: false, $button-v-i: $gf, $button-v-d: $gf, $button-h-i: $gf, $button-h-d: $gf, $thumb-v-bg: $gb, $thumb-v-shadow: false, $thumb-radius: null, $thumb-v-hover-bg: $g8, $thumb-h-bg: $gb, $thumb-h-hover-bg: $g8, $inactive-bg: $gd) {
  @if $size {
    ::-webkit-scrollbar {
      @include square($size);
    }
  }

  @if $corner-bg {
    ::-webkit-scrollbar-corner {
      @include background($corner-bg);
    }
  }

  @if $piece-bg or $piece-radius {
    ::-webkit-scrollbar-track-piece {
      @if $piece-bg {
        @include background($piece-bg);
      }

      @if $piece-radius {
        @include border-radius($piece-bg);
      }
    }
  }

  @if $resize-bg {
    ::-webkit-resizer:vertical {
      @include background($resize-bg);
    }
  }

  ::-webkit-scrollbar-button {
    @if $button-bg {
      @include background($button-bg);

      &:start:decrement,
      &:end:increment {
        display: block;
      }

      @if $button-v-i {
        &:vertical:increment {
          @include background($button-v-i);
        }
      }

      @if $button-v-d {
        &:vertical:decrement {
          @include background($button-v-d);
        }
      }

      @if $button-h-i {
        &:horizontal:increment {
          @include background($button-h-i);
        }
      }

      @if $button-h-d {
        &:horizontal:decrement {
          @include background($button-h-d);
        }
      }
    }

    @else {
      &:start:decrement,
      &:end:increment {
        width: 0;
        height: 0;
      }
    }
  }

  ::-webkit-scrollbar-thumb {
    @if $thumb-v-bg {
      @include background($thumb-v-bg);
    }

    @if $thumb-v-shadow {
      box-shadow: $thumb-v-shadow;
    }

    @if $thumb-radius {
      border-radius: $thumb-radius;
    }

    @if $thumb-v-hover-bg {
      &:hover {
        @include background($thumb-v-hover-bg);
      }
    }

    &:horizontal {
      @if $thumb-h-bg {
        @include background($thumb-h-bg);
      }

      @if $thumb-h-hover-bg {
        &:hover {
          @include background($thumb-h-hover-bg);
        }
      }
    }

    @if $inactive-bg {
      &:window-inactive {
        @include background($inactive-bg);
      }
    }
  }
}

//-----------------------------------------------------------------
//-----                  其它标签                             -----
//-----------------------------------------------------------------
$tab-wrap-bg: tab_wrap_on;
$tag-bg: tag;
$tag-bg-on: tag_on;
$switch-tag-bg: switch_tag;
$widget-head-bg: widget_head_bg;
$widget-head-tag: widget_head_tag;
$icon-printer: printer;
$btn-add-cut-bg: button_add_cut;

$valid-error-icon: warning;
$valid-error-color: $color-error;
$valid-error-bg: mix($valid-error-color, white, 10%);

$msgbox-text-color: $main-text-color;
$msgbox-bd-color: $color-success;
$msgbox-bg-color: mix($msgbox-bd-color, white, 10%);
$msgbox-warn-bd-color: $color-warn;
$msgbox-warn-bg-color: mix($msgbox-warn-bd-color, white, 10%);
$msgbox-exc-bd-color: $color-error;
$msgbox-exc-bg-color: mix($msgbox-exc-bd-color, white, 10%);
